import request from "@/utils/request";

// 新建角色
// http://120.211.58.75:50003/admin.schoolAdminPower/addAdminRole
export const addAdminRole = (data) => {
  // console.log(data);
  return request({
    url: "/admin.schoolAdminPower/addAdminRole",
    method: "POST",
    data,
  });
};

// 角色列表
// http://120.211.58.75:50003/admin.schoolAdminUser/searchAdminUserPage
// http://120.211.58.75:50003/admin.schoolAdminPower/searchAdminRolePage
export const searchAdminRolePage = (data) => {
  // console.log(data);
  return request({
    url: "/admin.schoolAdminPower/searchAdminRolePage",
    method: "POST",
    data,
  });
};
// 修改角色
// http://120.211.58.75:50003/admin.schoolAdminPower/editAdminRole
export const editAdminRole = (data) => {
  // console.log(data);
  return request({
    url: "/admin.schoolAdminPower/editAdminRole",
    method: "POST",
    data,
  });
};
// 删除角色
// http://120.211.58.75:50003/admin.schoolAdminPower/deleteAdminRole
// http://120.211.58.75:50003/admin.schoolAdminPower/deleteAdminRole
export const deleteAdminRole = (data) => {
  // console.log(data);
  return request({
    url: "/admin.schoolAdminPower/deleteAdminRole",
    method: "POST",
    data,
  });
};
// 禁用角色
// http://120.211.58.75:50003/admin.schoolAdminPower/prohibitRole
export const prohibitRole = (data) => {
  // console.log(data);
  return request({
    url: "/admin.schoolAdminPower/prohibitRole",
    method: "POST",
    data,
  });
};
